package com.wbt.aspectj;


import org.aspectj.lang.JoinPoint;
import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Before;
import org.aspectj.lang.annotation.Pointcut;
import org.springframework.core.annotation.Order;
import org.springframework.stereotype.Component;

@Aspect
@Component
@Order(1)
public class TestAop {


    @Pointcut("execution(* com.wbt.service.*.*(..))")
    public void cut(){
        System.out.println("Aspect cut!");
    }

    @Before("cut()")
    public void before(JoinPoint point){
        System.out.println("Aspect before!");

    }
}
